Thanks!
--
Samson Fu
| I have a Listview with checkbox.
| How do you disable some items (Not the whole listview)? So user
| cannot check/uncheck that items.
Write an OnChanging event handler, test for Change = ctState and set
AllowChange to False if you want the user not to be able to
check/uncheck an item.
procedure TForm1.ListView1Changing(Sender: TObject; Item: TListItem;
Change: TItemChange; var AllowChange: Boolean);
begin
if (Change = ctState) and YourIsItemDisabled(Item) then
AllowChange := False;
end;
HTH